<template>
<div>
    <van-nav-bar
      title="不凡"
      left-text="返回"
      left-arrow
      @click-left="onClickLeft"
    />
    <div class="f4"></div>
    <div class="collect">我的收藏</div>
    <div class="col1" v-for="item in list" :key="item.id">
        <div class="col2"><img :src="item.list_pic_url"></div>
        <div class="col3">{{item.name}}</div>
        <div class="col4">￥{{item.retail_price}}</div>
    </div>
</div>
  
</template>

<script>
import {listaction} from '@/api/home/detail/collect/index1.js'
export default {
    data(){
        return{
            list:[]

        }
    },
    methods:{
        onClickLeft() {
            this.$router.go(-1)
      },
    },
    created(){
        listaction({
            openId:'18568185602',
            goodsId:this.$route.params.ids,
        })
        .then(res=>{
            console.log(res),
            this.list=res.collectGoodsList
            console.log(res.collectGoodsList)
        })
    
    }
    }
</script>

<style>
.f4{
    width: 375px;
    height: 1px;
    background-color: #f4f4f4;
}
.collect{
    width: 375px;
    height: 48px;
    line-height: 48px;
    font-size: 20px;
    font-weight: 900;
}
.col1{
    width: 185px;
    height: 240px;
    float: left;
}
.col2 img{
    width: 151px;
    height: 151px;
}
.col3{
    width: 151px;
    height: 25px;
    line-height: 25px;
    margin: 0 auto;
    text-align: left;
}
.col4{
    width: 151px;
    height: 25px;
    line-height: 25px;
    margin: 0 auto;
    text-align: left;
    color: #B4282D;
}

</style>